import request from '@/utils/request'

// 查询章节管理列表
export function listPlatformChapter(query) {
  return request({
    url: '/business/platformChapter/list',
    method: 'get',
    params: query
  })
}

// 查询章节管理详细
export function getPlatformChapter(baseId) {
  return request({
    url: '/business/platformChapter/' + baseId,
    method: 'get'
  })
}

// 新增章节管理
export function addPlatformChapter(data) {
  return request({
    url: '/business/platformChapter',
    method: 'post',
    data: data
  })
}

// 修改章节管理
export function updatePlatformChapter(data) {
  return request({
    url: '/business/platformChapter',
    method: 'put',
    data: data
  })
}

// 删除章节管理
export function delPlatformChapter(baseId) {
  return request({
    url: '/business/platformChapter/' + baseId,
    method: 'delete'
  })
}

// 查询章节列表
export function chapterList(query) {
  return request({
    url: '/business/platformChapter/chapterList',
    method: 'get',
    params: query
  })
}

// 新增章节管理
export function handleCopy(baseId) {
  return request({
    url: '/business/platformChapter/handleCopy/' + baseId,
    method: 'post'
  })
}
